import request from '../utils/request';

/**
 * 获取商品分页列表数据
 */
export const getGoodsListApi = ({
  page, limit, category1Id = '', category2Id = ''
}) => {
  return request(`/mall-api/goods/list/${page}/${limit}`, {
    category1Id,
    category2Id
  });
}

/**
 * 获取商品详情
 * @param {*} goodsId 商品id
 */
export const getGoodsDetailApi = (goodsId) => {
  return request(`/mall-api/goods/${goodsId}`);
}
